package moreStuff;
import java.awt.EventQueue;

import javax.swing.JFrame;
import javax.swing.JPanel;
import javax.swing.border.EmptyBorder;
import net.miginfocom.swing.MigLayout;
import java.awt.TextArea;
import java.awt.TextField;
import java.awt.Label;
import java.awt.Button;
import java.awt.Dimension;
import java.awt.List;


public class ClientMainFrame extends JFrame {

	private JPanel contentPane;

	/**
	 * Launch the application.
	 */
	public static void main(String[] args) {
		EventQueue.invokeLater(new Runnable() {
			public void run() {
				try {
					ClientMainFrame frame = new ClientMainFrame();
					frame.setVisible(true);
				} catch (Exception e) {
					e.printStackTrace();
				}
			}
		});
	}

	/**
	 * Create the frame.
	 */
	public ClientMainFrame() {
		setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
		setBounds(100, 100, 800, 600);
		contentPane = new JPanel();
		contentPane.setBorder(new EmptyBorder(5, 5, 5, 5));
		setContentPane(contentPane);
		contentPane.setLayout(new MigLayout("", "", ""));
		
		Label label = new Label("Chat window");
		contentPane.add(label, "cell 0 0");
		
		Label label_1 = new Label("Users");
		contentPane.add(label_1, "cell 1 0");
		
		TextArea textArea = new TextArea();
		textArea.setPreferredSize(new Dimension(1000, 1000));
		textArea.setEditable(false);
		contentPane.add(textArea, "cell 0 1,grow");
		
		List list = new List();
		contentPane.add(list, "flowy,cell 1 1,grow");
		
		TextField textField = new TextField();
		contentPane.add(textField, "cell 0 2,grow");
		
		Button button = new Button("Start Game");
		contentPane.add(button, "flowx,cell 1 2");
		
		Label label_2 = new Label("Your opponent :");
		contentPane.add(label_2, "cell 1 1");
		
		TextField textField_1 = new TextField();
		textField_1.setEditable(false);
		contentPane.add(textField_1, "cell 1 1,growx");
		
		Button button_1 = new Button("       Exit       ");
		contentPane.add(button_1, "cell 1 2");
	}

}
